<!DOCTYPE html>
<html lang="en">
    <head>
        <title>头条新闻</title>
        <meta charset="utf-8">
        <meta content="width=device-width,initial-scale=1.0,maximum-scale=1.0,user-scalable=0" name="viewport"/>
        <link rel="stylesheet" type="text/css" href="../css/lib.min.css" />
        <script type="text/javascript" src="../js/lib.min.js"></script>
        <script language="JavaScript" src="http://cbjs.baidu.com/js/m.js"></script>
    </head>
   <body>
        <section class="g-flexview">
            <div class="toast">
                <p class="downloadTip"></p>
            </div>
            <section class="g-scrollview hidden">
                <div id="mescroll" class="mescroll">
                    <div class="header-container">
                        <div id="search-container">
                            <form class="search" method="get" autocomplete="off">
                                <input type="search" autocomplete="off" autocorrect="off" placeholder="搜索一下" maxlength="64" id="index-kw" name="keyword">
                                <div class="se-inner">
                                    <button id="index-bn" class="se-bn" type="submit"></button>
                                </div>
                            </form>
                        </div>
                        <nav class="nav-lists">
                            <!-- 导航 -->
                            <li>
                                <a href="#">
                                    <div class="nav-icon"> 
                                    </div>
                                    <span></span>
                                </a>
                            </li>
                        </nav>
                    </div>
                    <div id="navWarp">
                        <ul id="navContent" class="nav">
                            <!-- <li class="active" i="0">全部</li> -->
                        </ul>
                    </div>
                    <!--upscrollWarp用于装载上拉进度和数据列表,避免清空列表不满屏,导致点击悬浮菜单时会滑下来-->
                    <div id="upscrollWarp">
                        <!--展示上拉加载的数据列表-->
                        <ul id="dataList" class="data-list">
                        </ul>
                    </div>
                </div>
            </section>
        </section>
        <div class="native-loading-wrap">
            <span class="native-loading"></span>
        </div>
    </body>
    <script id="card" type="text/html" >
         {{each articles as data index}}
            {{if data.style_type == 1}}
             <!-- 左文右图 -->
                    <div class="card s6" >
                        <a href="{{ data.url }}">
                            <div class="card_middle">
                                <div class="card_img">
                                    <img class="lazy" data-original="{{ $imports.crop( data.thumbnails[0].url,1,400,330) }}"  alt="" />
                                </div>
                                <div class="card_content">
                                    <h3 class="news-title">{{ data.title }}</h3>
                                      <p class="news-info">
                                         <span class="news_source">{{  data.source_name  }}</span>
                                         <span class="news_time">{{ $imports.formatDate(data.publish_time)  }}</span>
                                         <span class="news_comment">{{ data.comment_count }}条评论</span>
                                     </p>
                                </div>
                            </div>                                          
                        </a>
                    </div>
                {{ else if data.style_type == 2 }}
                <!-- 视频 -->
                    <div class="card s6" name="{{ data.url }}">
                        <a href="{{ data.url }}">
                            <div class="card_middle">
                                <div class="card_img">
                                    <img class="lazy" data-original="{{ data.thumbnails[0].url }}"  alt="" />
                                    <span class="play-btn"></span>
                                </div>
                                <div class="card_content">
                                    <h3 class="news-title">{{ data.title }}</h3>
                                      <p class="news-info">
                                         <span class="news_source">{{  data.source_name  }}</span>
                                         <span class="news_time">{{ $imports.formatDate(data.publish_time)  }}</span>
                                         <span class="news_comment">{{ data.comment_count }}条评论</span>
                                     </p>
                                </div>
                            </div>                                          
                        </a>
                    </div>
                {{ else if data.style_type == 3 }}
                        <!-- 大图 -->
                        <div class="card s2">
                                <a href="{{ data.url }}">
                                        <h3 class="news-title">{{ data.title }}</h3>
                                        <div class="big_pic">
                                            <img  class="lazy" data-original="{{ $imports.crop( data.thumbnails[0].url,1,690,330) }}" alt="" />
                                        </div>
                                         <p class="news-info">
                                            <span class="news_source">{{  data.source_name  }}</span>
                                            <span class="news_time">{{ $imports.formatDate(data.publish_time)  }}</span>
                                            <span class="news_comment">{{ data.comment_count }}条评论</span>
                                        </p>
                                </a>
                         </div>
                {{ else if data.style_type == 4 }}
                        <!-- 纯文本 -->
                        <div class="card s4">
                            <a href="{{ data.url }}">
                                <div class="card_text">
                                        {{if data.title && data.title!="" }}
                                            <h3>{{ data.title }}</h3>
                                        {{ else if data.summary && data.summary!="" }}
                                            <h3>{{ data.summary }}</h3>
                                       {{else }}
                                            <h3>{{ data.content }}</h3>   
                                       {{/if }} 
                                    <div  class="more"><p>更多</p></div>
                                </div>
                                <p class="news-info">
                                     <span class="news_source">{{  data.source_name  }}</span>
                                     <span class="news_time">{{ $imports.formatDate(data.publish_time)  }}</span>
                                     <span class="news_comment">{{ data.comment_count }}条评论</span>
                                </p>
                            </a>
                        </div> 
                {{ else if data.style_type == 5 }}
                    <!-- 三图模式 -->
                    <div class="card s1">
                            <a href="{{ data.url }}">
                                <h3 class="news-title">{{ data.title }}</h3>
                                <ul class="lists_img">
                                    <li class="list_wrap_img">
                                        <img class="lazy" data-original="{{ $imports.crop(data.thumbnails[0].url,1,367,240) }}" alt="" />
                                    </li>
                                    <li class="list_wrap_img">
                                        <img class="lazy" data-original="{{ $imports.crop(data.thumbnails[1].url,1,367,240) }}" alt="" />
                                    </li>
                                    <li class="list_wrap_img">
                                        <img class="lazy" data-original="{{ $imports.crop(data.thumbnails[2].url,1,367,240) }}" alt="" />
                                    </li>
                                </ul>
                                 <p class="news-info">
                                     <span class="news_source">{{  data.source_name  }}</span>
                                     <span class="news_time">{{ $imports.formatDate(data.publish_time)  }}</span>
                                     <span class="news_comment">{{ data.comment_count }}条评论</span>
                                </p>
                            </a>
                    </div>
                {{ else if data.style_type == 6 }}
                    <!-- 左文右图 -->
                     <div class="card s5" name="{{ data.url }}">
                        <a href="javascript:void(0)">
                            <div class="card_middle">
                                <div class="card_img">
                                    <img class="lazy" data-original="{{ $imports.crop( data.thumbnails[0].url,1,400,330) }}"  alt="" />
                                    <span class="play-btn"></span>
                                </div>
                                <div class="card_content">
                                    <h3 class="news-title">{{ data.title }}</h3>
                                      <p class="news-info">
                                         <span class="news_source">{{  data.source_name  }}</span>
                                         <span class="news_time">{{ $imports.formatDate(data.publish_time)  }}</span>
                                         <span class="news_comment">{{ data.comment_count }}条评论</span>
                                     </p>
                                </div>
                            </div>                                          
                        </a>
                    </div>
                {{ else if data.style_type == 10 }}
                    <!-- 三图图集模式 -->
                    <div class="card s10">
                            <a href="{{ data.url }}">
                                <h3 class="news-title">{{ data.title }}</h3>
                                <ul class="lists_pic">
                                    <li class="list_wrap_pic">
                                        <img class="lazy" src="http://c1.adline.com.cn/static/img/cf/placeholder_crop226x286.png" data-original="{{ $imports.crop(data.thumbnails[0].url,2,226,286) }}" alt="" />
                                    </li>
                                    <li class="list_wrap_pic">
                                        <img class="lazy" src="http://c1.adline.com.cn/static/img/cf/placeholder_crop226x286.png" data-original="{{ $imports.crop(data.thumbnails[1].url,2,226,286) }}" alt="" />
                                    </li>
                                    <li class="list_wrap_pic">
                                        <img class="lazy" src="http://c1.adline.com.cn/static/img/cf/placeholder_crop226x286.png" data-original="{{ $imports.crop(data.thumbnails[2].url,2,226,286) }}" alt="" />
                                    </li>
                                </ul>
                                 <p class="news-info">
                                </p>
                            </a>
                    </div>
                {{ else if data.style_type == 101 }}
                    <div class="cctv1" id="{{data.uni_token}}"></div>
                {{ else if data.style_type == 102 }}
                    <div class="cctv2" id="{{data.uni_token}}" >
                        <iframe  scrolling="no" frameborder="0" align="center,center"  marginheight="0" allowtransparency="true" marginwidth="0" style='height:0;width:100%;'></iframe>
                    </div>              
            {{ /if }}
         {{/each}}
    </script>
    <script type="text/javascript" src="../js/index.min.js"></script>
</html>